package com.phiture.erp.common.enums;


import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Arrays;
import java.util.Map;
import java.util.stream.Collectors;

@Getter
@AllArgsConstructor
public enum ErpProductionTaskPriorityEnum {
    /**
     * 紧急优先级
     */
    URGENT(1, "紧急"),
    /**
     * 高优先级
     */
    HIGH(2, "高"),
    /**
     * 中优先级
     */
    MEDIUM(3, "中"),
    /**
     * 低优先级
     */
    LOW(4, "低");
    private final Integer code;
    private final String name;

    public static Map<Integer, String> getMap() {
        return Arrays.stream(values()).collect(Collectors.toMap(ErpProductionTaskPriorityEnum::getCode, ErpProductionTaskPriorityEnum::getName));
    }

}
